package com.sloera.spring.tx.xml;

import java.util.List;

/**
 * @author sloera
 * @create 2020/4/12
 */
public class CashierImpl implements Cashier {
    private BookShopSservice bookShopSservice;

    public void setBookShopSservice(BookShopSservice bookShopSservice) {
        this.bookShopSservice = bookShopSservice;
    }

    @Override
    public void checkout(String username, List<String> isbns) {
        for (String isbn : isbns) {
            bookShopSservice.purchase(username, isbn);
        }
    }
}
